<?php
/**
 * User: zhaoguofeng
 * Date: 2022/1/27
 * Time: 9:53
 */

namespace app\factoryMethod;

abstract class Dialog
{
    public function render()
    {
        $button = $this->createButton();
        $button->onclick();
        $button->render();
    }

    abstract function createButton(): Button;
}